/*
 *    Copyright (c) 2018-2025, lengleng All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 * Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * Neither the name of the pig4cloud.com developer nor the names of its
 * contributors may be used to endorse or promote products derived from
 * this software without specific prior written permission.
 * Author: lengleng (wangiegie@gmail.com)
 */

package com.pig4cloud.pig.mt.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotEmpty;
import java.util.Date;

/**
 * CMS文章中心
 *
 * @author JLM
 * @date 2021-03-05 11:45:08
 */
@Data
@TableName("wx_article")
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "CMS文章中心")
public class WxArticle extends Model<WxArticle> {
private static final long serialVersionUID = 1L;

    /**
     * 
     */
    @TableId(type = IdType.ASSIGN_UUID)
    @ApiModelProperty(value="")
    private String id;
    /**
     * 文章类型
     */
    @ApiModelProperty(value="文章类型")
    private Integer type;
    /**
     * 标题
     */
    @ApiModelProperty(value="标题")
	@TableField(insertStrategy = FieldStrategy.IGNORED)//title重复则不插入
	@NotEmpty(message = "标题不得为空")
    private String title;
    /**
     * 文章摘要
     */
    @ApiModelProperty(value="文章摘要")
    private String summary;
    /**
     * 文章标签
     */
    @ApiModelProperty(value="文章标签")
    private String tags;
    /**
     * 内容
     */
    @ApiModelProperty(value="内容")
    private String content;
    /**
     * 分类
     */
    @ApiModelProperty(value="分类")
    private String category;
    /**
     * 二级目录
     */
    @ApiModelProperty(value="二级目录")
    private String subCategory;
    /**
     * 创建时间
     */
    @ApiModelProperty(value="创建时间")
    private Date createTime;
    /**
     * 修改时间
     */
    @ApiModelProperty(value="修改时间")
    private Date updateTime;
    /**
     * 点击次数
     */
    @ApiModelProperty(value="点击次数")
    private Long openCount;
    /**
     * 指向外链
     */
    @ApiModelProperty(value="指向外链")
    private String targetLink;
    /**
     * 文章首图
     */
    @ApiModelProperty(value="文章首图")
    private String image;
    }
